<?php /* Smarty version 2.6.12, created on 2008-10-30 14:09:06
         compiled from modules/Manufacturers/manufacturers.tpl */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'escape', 'modules/Manufacturers/manufacturers.tpl', 9, false),array('modifier', 'default', 'modules/Manufacturers/manufacturers.tpl', 82, false),array('modifier', 'strip_tags', 'modules/Manufacturers/manufacturers.tpl', 97, false),array('function', 'cycle', 'modules/Manufacturers/manufacturers.tpl', 78, false),)), $this); ?>
<?php func_load_lang($this, "modules/Manufacturers/manufacturers.tpl","lbl_manufacturers,txt_manufacturers_delete_msg,txt_manufacturers_top_text,txt_manufacturers_note_pro,txt_manufacturers_notes,txt_manufacturers_note_pro_provider,lbl_check_all,lbl_uncheck_all,lbl_manufacturer,lbl_provider,lbl_products,lbl_orderby,lbl_active,lbl_manuf_owner_lost,txt_not_available,txt_not_available,txt_manufacturers_special_note,lbl_delete_selected,lbl_update,txt_no_manufacturers,lbl_add_new_,lbl_manufacturers_list,lbl_manufacturers_list,lbl_add_manufacturer,txt_manufacturer_edit_warning,txt_manufacturers_warning,lbl_manufacturer,lbl_logo,lbl_save,lbl_description,lbl_url,lbl_orderby,lbl_availability,lbl_save,lbl_manufacturer_details"); ?><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "page_title.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_manufacturers'])));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
  if ($this->_tpl_vars['active_modules']['HTML_Editor']):  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "modules/HTML_Editor/editor.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
  endif; ?>

<script type="text/javascript">
<!--
var txt_manufacturers_delete_msg = "<?php echo ((is_array($_tmp=$this->_tpl_vars['lng']['txt_manufacturers_delete_msg'])) ? $this->_run_mod_handler('escape', true, $_tmp, 'javascript') : smarty_modifier_escape($_tmp, 'javascript')); ?>
";
-->
</script>

<?php if ($this->_tpl_vars['usertype'] == 'A' || ( $this->_tpl_vars['active_modules']['Simple_Mode'] != "" && $this->_tpl_vars['usertype'] == 'P' )):  $this->assign('administrate', 'Y');  endif; ?>

<?php echo $this->_tpl_vars['lng']['txt_manufacturers_top_text']; ?>


<?php if ($this->_tpl_vars['active_modules']['Simple_Mode'] == ""): ?>
<br /><br />

<?php echo $this->_tpl_vars['lng']['txt_manufacturers_note_pro']; ?>

<?php endif; ?>

<?php if ($this->_tpl_vars['single_mode'] == ""): ?>
<br /><br />

<?php echo $this->_tpl_vars['lng']['txt_manufacturers_notes']; ?>


<?php if ($this->_tpl_vars['active_modules']['Simple_Mode'] == "" && $this->_tpl_vars['usertype'] == 'P'):  echo $this->_tpl_vars['lng']['txt_manufacturers_note_pro_provider']; ?>

<?php endif; ?>

<?php endif; ?>

<br /><br />

<?php if ($this->_tpl_vars['mode'] != 'manufacturer_info'): ?>

<?php ob_start(); ?>

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "customer/main/navigation.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php if ($this->_tpl_vars['manufacturers'] != ""): ?>

<script type="text/javascript" language="JavaScript 1.2">
<!--
checkboxes_form = 'manufform';
checkboxes = new Array(<?php $_from = $this->_tpl_vars['manufacturers']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['v']):
 if ($this->_tpl_vars['k'] > 0): ?>,<?php endif; ?>'<?php if (! ( $this->_tpl_vars['administrate'] == "" && ( $this->_tpl_vars['v']['provider'] != $this->_tpl_vars['login'] || $this->_tpl_vars['v']['used_by_others'] > 0 ) )): ?>to_delete[<?php echo $this->_tpl_vars['v']['manufacturerid']; ?>
]<?php endif; ?>'<?php endforeach; endif; unset($_from); ?>);
 
-->
</script>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/include_js.tpl", 'smarty_include_vars' => array('src' => "change_all_checkboxes.js")));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<div style="line-height:170%"><a href="javascript:change_all(true);"><?php echo $this->_tpl_vars['lng']['lbl_check_all']; ?>
</a> / <a href="javascript:change_all(false);"><?php echo $this->_tpl_vars['lng']['lbl_uncheck_all']; ?>
</a></div>

<?php endif; ?>

<form action="manufacturers.php" method="post" name="manufform">
<input type="hidden" name="mode" value="update" />
<input type="hidden" name="page" value="<?php echo $this->_tpl_vars['page']; ?>
" />

<table cellpadding="3" cellspacing="1" width="100%">

<tr class="TableHead">
	<?php if ($this->_tpl_vars['manufacturers'] != ""): ?><td width="10">&nbsp;</td><?php endif; ?>
	<td width="40%"><?php echo $this->_tpl_vars['lng']['lbl_manufacturer']; ?>
</td>
	<td width="30%"><?php echo $this->_tpl_vars['lng']['lbl_provider']; ?>
</td>
	<td width="20%" align="center"><?php echo $this->_tpl_vars['lng']['lbl_products']; ?>
</td>
	<td width="30" align="center"><?php echo $this->_tpl_vars['lng']['lbl_orderby']; ?>
</td>
	<td width="30" align="center"><?php echo $this->_tpl_vars['lng']['lbl_active']; ?>
</td>
</tr>

<?php if ($this->_tpl_vars['manufacturers'] != ""): ?>

<?php $_from = $this->_tpl_vars['manufacturers']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['v']):
?>

<tr<?php echo smarty_function_cycle(array('values' => ", class='TableSubHead'"), $this);?>
>
	<td align="center"><input type="checkbox" name="to_delete[<?php echo $this->_tpl_vars['v']['manufacturerid']; ?>
]"<?php if ($this->_tpl_vars['administrate'] == "" && ( $this->_tpl_vars['v']['provider'] != $this->_tpl_vars['login'] || $this->_tpl_vars['v']['used_by_others'] > 0 )): ?> disabled="disabled"<?php endif; ?> /></td>
	<td><b><a href="manufacturers.php?manufacturerid=<?php echo $this->_tpl_vars['v']['manufacturerid'];  if ($this->_tpl_vars['page']): ?>&amp;page=<?php echo $this->_tpl_vars['page'];  endif; ?>"><?php echo $this->_tpl_vars['v']['manufacturer']; ?>
</a></b></td>
	<td><?php if ($this->_tpl_vars['v']['is_provider'] == 'Y'):  echo $this->_tpl_vars['v']['provider_name'];  else:  echo $this->_tpl_vars['lng']['lbl_manuf_owner_lost'];  endif;  if ($this->_tpl_vars['administrate']): ?> (<?php echo $this->_tpl_vars['v']['provider']; ?>
)<?php endif; ?></td>
	<td align="center"><?php echo ((is_array($_tmp=@$this->_tpl_vars['v']['products_count'])) ? $this->_run_mod_handler('default', true, $_tmp, @$this->_tpl_vars['lng']['txt_not_available']) : smarty_modifier_default($_tmp, @$this->_tpl_vars['lng']['txt_not_available']));  if ($this->_tpl_vars['v']['used_by_others'] > 0): ?>*<?php $this->assign('show_note', 'Y');  endif; ?></td>
	<td align="center"><input type="text" name="records[<?php echo $this->_tpl_vars['v']['manufacturerid']; ?>
][orderby]" size="5" value="<?php echo $this->_tpl_vars['v']['orderby']; ?>
"<?php if ($this->_tpl_vars['administrate'] == ""): ?> disabled="disabled"<?php endif; ?> /></td>
	<td align="center"><input type="checkbox" name="records[<?php echo $this->_tpl_vars['v']['manufacturerid']; ?>
][avail]" value="Y"<?php if ($this->_tpl_vars['v']['avail'] == 'Y'): ?> checked="checked"<?php endif;  if ($this->_tpl_vars['administrate'] == ""): ?> disabled="disabled"<?php endif; ?> /></td>
</tr>

<?php endforeach; endif; unset($_from); ?>

<?php if ($this->_tpl_vars['show_note'] == 'Y'): ?>
<tr>
	<td colspan="6"><br /><?php echo $this->_tpl_vars['lng']['txt_manufacturers_special_note']; ?>
</td>
</tr>
<?php endif; ?>

<tr>
	<td colspan="6" class="SubmitBox">
	<input type="button" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_delete_selected'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" onclick="javascript: if (checkMarks(this.form, new RegExp('^to_delete\\[.+\\]', 'gi')) && confirm(txt_manufacturers_delete_msg)) submitForm(this.form, 'delete');" />
	<input type="submit" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_update'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" />
	</td>
</tr>

<?php else: ?>

<tr>
	<td colspan="6" align="center"><br /><?php echo $this->_tpl_vars['lng']['txt_no_manufacturers']; ?>
</td>
</tr>

<?php endif; ?>

<tr>
<td colspan="6"><br /><input type="button" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_add_new_'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" onclick="javascript: self.location = 'manufacturers.php?mode=add';" /></td>
</tr>

</table>

</form>

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "customer/main/navigation.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php $this->_smarty_vars['capture']['dialog'] = ob_get_contents(); ob_end_clean();  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "dialog.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_manufacturers_list'],'content' => $this->_smarty_vars['capture']['dialog'],'extra' => 'width="100%"')));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php else: ?>

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/include_js.tpl", 'smarty_include_vars' => array('src' => "main/popup_image_selection.js")));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php ob_start(); ?>

<div align="right">
<table cellspacing="0" cellpadding="0">
<tr>
	<td><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "buttons/button.tpl", 'smarty_include_vars' => array('button_title' => $this->_tpl_vars['lng']['lbl_manufacturers_list'],'href' => "manufacturers.php?page=".($this->_tpl_vars['page']))));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?></td>
<?php if ($this->_tpl_vars['manufacturer']['manufacturerid']): ?>
	<td>&nbsp;&nbsp;&nbsp;&nbsp;</td>
	<td><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "buttons/button.tpl", 'smarty_include_vars' => array('button_title' => $this->_tpl_vars['lng']['lbl_add_manufacturer'],'href' => "manufacturers.php?mode=add&page=".($this->_tpl_vars['page']))));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?></td>
<?php endif; ?>
</tr>
</table>
</div>

<?php if ($this->_tpl_vars['administrate'] == "" && $this->_tpl_vars['login'] != $this->_tpl_vars['manufacturer']['provider'] && $GLOBALS['HTTP_GET_VARS']['mode'] != 'add'):  $this->assign('disabled', ' disabled'); ?>
<br />
<font class="ErrorMessage"><?php echo $this->_tpl_vars['lng']['txt_manufacturer_edit_warning']; ?>
</font>
<br />

<?php elseif ($this->_tpl_vars['administrate'] == "" && $this->_tpl_vars['manufacturer']['used_by_others'] > 0): ?>
<br />
<font class="ErrorMessage"><?php echo $this->_tpl_vars['lng']['txt_manufacturers_warning']; ?>
</font>
<br />
<?php endif; ?>

<br />

<?php if ($this->_tpl_vars['manufacturer']['manufacturerid'] != ''):  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/language_selector.tpl", 'smarty_include_vars' => array('script' => "manufacturers.php?manufacturerid=".($this->_tpl_vars['manufacturer']['manufacturerid'])."&")));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
  endif; ?>
<form action="manufacturers.php" method="post" enctype="multipart/form-data">
<input type="hidden" name="mode" value="details" />
<input type="hidden" name="manufacturerid" value="<?php echo $this->_tpl_vars['manufacturer']['manufacturerid']; ?>
" />
<input type="hidden" name="page" value="<?php echo $this->_tpl_vars['page']; ?>
" />

<table cellpadding="3" cellspacing="1" width="100%">

<tr>
	<td width="20%" class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_manufacturer']; ?>
:</td>
	<td><font class="Star">*</font></td>
	<td width="80%"><input type="text" name="manufacturer" size="50" value="<?php echo ((is_array($_tmp=$this->_tpl_vars['manufacturer']['manufacturer'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" style="width:80%"<?php echo $this->_tpl_vars['disabled']; ?>
 /></td>
</tr>

<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_logo']; ?>
:</td>
	<td>&nbsp;</td>
	<?php if ($this->_tpl_vars['manufacturer']['is_image'] == 'Y'):  $this->assign('no_delete', "");  else:  $this->assign('no_delete', 'Y');  endif; ?>
	<td><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/edit_image.tpl", 'smarty_include_vars' => array('type' => 'M','id' => $this->_tpl_vars['manufacturer']['manufacturerid'],'delete_url' => "manufacturers.php?mode=delete_image&manufacturerid=".($this->_tpl_vars['manufacturer']['manufacturerid']),'button_name' => $this->_tpl_vars['lng']['lbl_save'],'no_delete' => $this->_tpl_vars['no_delete'])));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?></td>
</tr>

<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_description']; ?>
:</td>
	<td>&nbsp;</td>
	<td>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/textarea.tpl", 'smarty_include_vars' => array('name' => 'descr','cols' => 55,'rows' => 10,'class' => 'InputWidth','data' => $this->_tpl_vars['manufacturer']['descr'],'width' => "80%",'btn_rows' => 3)));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
	</td>
</tr>

<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_url']; ?>
:</td>
	<td>&nbsp;</td>
	<td><input type="text" size="50" name="url" value="<?php echo ((is_array($_tmp=$this->_tpl_vars['manufacturer']['url'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" style="width:80%"<?php echo $this->_tpl_vars['disabled']; ?>
 /></td>
</tr>

<?php if ($this->_tpl_vars['administrate'] == 'Y'): ?>
<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_orderby']; ?>
:</td>
	<td>&nbsp;</td>
	<td><input type="text" name="orderby" size="5" value="<?php echo ((is_array($_tmp=@$this->_tpl_vars['manufacturer']['orderby'])) ? $this->_run_mod_handler('default', true, $_tmp, '0') : smarty_modifier_default($_tmp, '0')); ?>
" /></td>
</tr>

<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_availability']; ?>
:</td>
	<td>&nbsp;</td>
	<td><input type="checkbox" name="avail" value="Y"<?php if ($this->_tpl_vars['manufacturer']['avail'] == 'Y' || $this->_tpl_vars['manufacturer']['manufacturerid'] == ''): ?> checked="checked"<?php endif; ?> /></td>
</tr>
<?php endif; ?>

<tr>
	<td colspan="2">&nbsp;</td>
	<td><input type="submit" value=" <?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_save'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
 "<?php echo $this->_tpl_vars['disabled']; ?>
 /></td>
</tr>

</table>
</form>

<?php $this->_smarty_vars['capture']['dialog'] = ob_get_contents(); ob_end_clean();  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "dialog.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_manufacturer_details'],'content' => $this->_smarty_vars['capture']['dialog'],'extra' => 'width="100%"')));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php endif; ?>
